from flask_restful import fields

book_fields = {
    'id' : fields.Integer,
    'book_name' : fields.String,
    'book_auther' : fields.Integer,
    'book_price' : fields.Float,
}

auther_fields = {
    "id" : fields.Integer,
    "name" : fields.String,
    "gender" : fields.String,
    'pen_name':fields.String
}


coursetag_fields = {
    "id": fields.Integer,
    "tag_name": fields.String,
    "sequence": fields.Integer,
}

course_fields = {
    "id": fields.Integer,
    "course_name": fields.String,
    "course_status": fields.Integer,
    "course_img": fields.String,
    "course_introduce": fields.String,
    "learner": fields.Integer,
    "course_type": fields.String,
    "attention": fields.Integer,
    'cate_type' : fields.Integer,
    'create_time':fields.DateTime,
}


courseantag_fields = {
    'id' : fields.Integer,
    'course_id' : fields.Integer,
    'tag_id' : fields.Integer,
}

chapters_fields = {
    'id': fields.Integer,
    'title': fields.String,
    'serial_num': fields.Integer,
}

comment_fields = {
    'id': fields.Integer,
    'user': fields.Integer,
    'comment_time': fields.DateTime,
    'comment_content': fields.String,
    'zan_num': fields.Integer,
    'parent_id': fields.Integer,
    'course': fields.Integer,
    'reply_count': fields.Integer,
}

user_fields = {
    'id':fields.Integer,
    'mobile':fields.String,
    'password':fields.String,
    'nick_name':fields.String,
    'gender':fields.Integer,
    'profile_photo':fields.String,
    'created_time':fields.DateTime,
    'username':fields.String,
    'email':fields.String,
}


sections_fields = {
    'id':fields.Integer,
    'section_title':fields.String,
    'serial_num':fields.Integer,
    'chapters':fields.Integer,
    'learn_time':fields.Float,
    'video_url':fields.String,
    'like_count':fields.Integer,
}

vip_fields = {
    # 'level':fields.Integer,
    'price':fields.Float,
    'vip_cour':fields.Integer,
    'exempt_cour':fields.Integer,
    'save':fields.Integer,
    'environment': fields.Integer,
    'client':fields.Integer,
    'ssh':fields.Integer,
    "web_ide":fields.Integer,
    'discounts':fields.Integer,
    'exempt_study':fields.Integer
}


path_fields = {
    'id':fields.Integer,
    'title': fields.String,
    'ser_num': fields.Integer,
    'img': fields.String,
    'desc': fields.String,
    'section_num': fields.Integer,
    'study_time': fields.Float,
    'add_num': fields.Integer
}